<template>
  <div id="couponxq">  

  <el-form ref="form"  label-width="80px">           
          <el-row>
            <el-col :span="12" >  
                <el-page-header @back="goBack"   :content='"派发详情"'  style="margin-top:10px;margin-bottom:20px;"></el-page-header>
            </el-col>
          </el-row>
         
    </el-form>

   <!-- 渲染数据list -->
   <couponxq-list :datalist="datalist" > </couponxq-list>

   <div style="margin-top:20px;text-align: center;">
      <el-pagination
        background
        @current-change="handleCurrentChange"
        :page-size="10"  
        layout="prev, pager, next, jumper"
        :total="count">
      </el-pagination>
    </div>

    

      
  </div>
</template>

<script>
import CouponxqList from '@/view/Jindou/CouponxqList'
export default {
  name: 'couponxq',
  data () {
    return {
        datalist:[],
        page:1,
        count:0,
    }
  },
 components:{
    CouponxqList
  },
  created(){
      this.list_fun()
  },
  mounted (){
    
  },
  methods: {
        list_fun(){
           this.post("/Goldbean/handoutlog", {
              page:this.page,
	        }).then(res => {
              this.count = res.result.count
              this.datalist = res.result.list
              //console.log(res,"aaacc")
         })
      },
    goBack() {
        this.$router.go(-1)
    },
     handleSizeChange(val) {
        console.log(`每页 ${val} 条`);
    },
    handleCurrentChange(val) {
        this.page = val
    
        console.log(`当前页: ${val}`);
      }
  }
}
</script>


<style scoped>
</style>
